//
//  UpQuestionViewController.m
//  Family
//
//  Created by 王声䘵 on 2018/5/5.
//  Copyright © 2018年 王声䘵. All rights reserved.
//

#import "UpQuestionViewController.h"

@interface UpQuestionViewController ()<UITextViewDelegate>
@property (weak, nonatomic) IBOutlet UITextView *Question;

@end

@implementation UpQuestionViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    _Question.delegate=self;
    // Do any additional setup after loading the view.
}

- (void)didReceiveMemoryWarning {
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}
- (IBAction)backUserView:(id)sender {
    [self.navigationController popViewControllerAnimated:YES];
}
//按回车回收键盘
-(BOOL)textView:(UITextView *)textView shouldChangeTextInRange:(NSRange)range replacementText:(NSString *)text
{
    if ([text isEqualToString:@"\n"]) {
        [textView resignFirstResponder];
        return NO;
    }
    return YES;
}
- (BOOL)textFieldShouldReturn:(UITextField *)textField
{
    //回收键盘,取消第一响应者
    [textField resignFirstResponder];
    return YES;
}
/*
#pragma mark - Navigation

// In a storyboard-based application, you will often want to do a little preparation before navigation
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender {
    // Get the new view controller using [segue destinationViewController].
    // Pass the selected object to the new view controller.
}
*/

@end
